// Copyright (C) 2022 Linlexiao
#ifndef YAKU_H
#define YAKU_H
#include "pai.h"

#define DECLAREYAKU(x, n)                         \
    class x : public Yaku {                       \
     public:                                      \
        int test(HandSet hand);                   \
        QString getName() { return QString(#n); } \
    }

class Yaku {
 public:
    Yaku();
    virtual int test(HandSet hand) = 0;  //返回计几番
    virtual QString getName() = 0;
};

DECLAREYAKU(MenzenTsumo, 门前清自摸和);
DECLAREYAKU(TanYao, 断幺九);
DECLAREYAKU(YakuhaiFieldEast, 场风牌 - 东);
DECLAREYAKU(YakuhaiFieldSouth, 场风牌 - 南);
DECLAREYAKU(YakuhaiFieldWest, 场风牌 - 西);
DECLAREYAKU(YakuhaiFieldNorth, 场风牌 - 北);
DECLAREYAKU(YakuhaiSeatEast, 自风牌 - 东);
DECLAREYAKU(YakuhaiSeatSouth, 自风牌 - 南);
DECLAREYAKU(YakuhaiSeatWest, 自风牌 - 西);
DECLAREYAKU(YakuhaiSeatNorth, 自风牌 - 北);
DECLAREYAKU(YakuhaiHako, 役牌 - 白);
DECLAREYAKU(YakuhaiHatsu, 役牌 - 发);
DECLAREYAKU(YakuhaiCyuu, 役牌 - 中);
DECLAREYAKU(ChanKan, 抢杠);
DECLAREYAKU(RinshanKaihou, 岭上开花);
DECLAREYAKU(HaiteiRaoyue, 海底捞月);
DECLAREYAKU(HouteiRaoyui, 河底摸鱼);
DECLAREYAKU(Riichi, 立直);
DECLAREYAKU(Iipeikou, 一杯口);
DECLAREYAKU(Pinfu, 平和);
DECLAREYAKU(Ippatsu, 一发);
DECLAREYAKU(Dora, 宝牌);
DECLAREYAKU(Ura, 里宝牌);
DECLAREYAKU(AkaDora, 赤宝牌);
DECLAREYAKU(Toitoi, 对对和);
DECLAREYAKU(Sanankou, 三暗刻);
DECLAREYAKU(SanshokuDoukou, 三色同刻);
DECLAREYAKU(Sankantsu, 三杠子);
DECLAREYAKU(Shousangen, 小三元);
DECLAREYAKU(Honroutou, 混老头);
DECLAREYAKU(DoubleRiichi, 双立直);
DECLAREYAKU(SanshokuDoujun, 三色同顺);
DECLAREYAKU(Ikkitsuukan, 一气通贯);
DECLAREYAKU(Chantaiyao, 混全带幺九);
DECLAREYAKU(Honiisou, 混一色);
DECLAREYAKU(Junchantaiyao, 纯全带幺九);
DECLAREYAKU(Ryanpeikou, 两杯口);
DECLAREYAKU(Chiniisou, 清一色);

DECLAREYAKU(Daisangen, 大三元);
DECLAREYAKU(Suuankou, 四暗刻);
DECLAREYAKU(SuuankouTanki, 四暗刻单骑);
DECLAREYAKU(Shousuushi, 小四喜);
DECLAREYAKU(Daisuushi, 大四喜);
DECLAREYAKU(Tsuuiisou, 字一色);
DECLAREYAKU(Ryuuiisou, 绿一色);
DECLAREYAKU(Chinroutou, 清老头);
DECLAREYAKU(ChuurenPoutou, 九莲宝灯);
DECLAREYAKU(JunseiChuurenPoutou, 纯正九莲宝灯);
DECLAREYAKU(Suukantsu, 四杠子);
DECLAREYAKU(Tenhou, 天和);
DECLAREYAKU(Chiihou, 地和);
#endif  // YAKU_H
